﻿using EM.OA.BLL;
using EM.OA.Common;
using EM.OA.DataModel.DBModel;
using EM.OA.WebCommon.Base;
using System;
using System.Collections.Generic;
using System.ComponentModel.DataAnnotations;
using System.Linq;
using System.Reflection;
using System.Web;
namespace EM.OA.Portal.Models
{
    public class WorkPlanModels : BaseViewModel
    {
        /// <summary>
        /// 计划ID
        /// </summary>		
        [Display(Name = "计划ID")]
        public Guid? WorkPlanID { get; set; }
        /// <summary>
        /// 计划名称
        /// </summary>		
        [Display(Name = "计划名称")]
        public string WorkPlanName { get; set; }
        /// <summary>
        ///计划类型 日，周，月，季度，年
        /// </summary>		
        [Display(Name = "计划类型")]
        public string WorkPlanType { get; set; }
        [Display(Name = "计划类型")]
        public string WorkPlanTypeName
        {
            get
            {
                return new DictionaryBLL().GetDicName(GlobalEnum.RootKind.WorkPlanKind.ToString(), WorkPlanType);
            }
        }
        /// <summary>
        /// 计划开始时间
        /// </summary>		
        [Display(Name = "计划开始时间")]
        public DateTime WorkPlanStartTime { get; set; }
        /// <summary>
        /// 计划内容
        /// </summary>		
        [Display(Name = "计划内容")]
        public string WorkPlanContent { get; set; }
        /// <summary>
        /// 计划总结
        /// </summary>		
        [Display(Name = "计划总结")]
        public string WorkPlanSummary { get; set; }
        /// <summary>
        /// 是否有附件
        /// </summary>		
        [Display(Name = "是否有附件")]
        public bool? HaveAttachment { get; set; }
        /// <summary>
        /// 多个用户以;号间隔，每次修改重新修改该字段
        /// </summary>		
        [Display(Name = "计划共享")]
        public string ShareUsers { get; set; }

        public string ShareUsersName
        {
            get
            {
                return new UserBLL().GetUserName(ShareUsers);
            }
        }

    }
}